package com.itheima.stock;

import com.itheima.stock.stocktimertesk.StockTimerTaskService;
import org.junit.jupiter.api.Test;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;

/**
 * @author: siwukun
 * @date: 2022/06/05
 * @description:
 */
@SpringBootTest
public class PullInnerStockInfos {

    @Autowired
    private StockTimerTaskService service;
    @Test
    public void pullInnerStockInfos(){
        service.pullInnerStockData();
    }


    @Test
    public void pullInnerStockIndexInfos(){
        Long start = System.currentTimeMillis();
        service.pullStockRtIndex();
        System.out.println("耗时"+ (System.currentTimeMillis()-start));
    }

    @Test
    public void getStockSectorRtIndex(){
        Long start = System.currentTimeMillis();
        service.getStockSectorRtIndex();
        System.out.println("耗时"+ (System.currentTimeMillis()-start));
    }

    @Test
    public void getStockOutSectorRtIndex(){
//        Long start = System.currentTimeMillis();
        service.StockOutMarketData();
//        System.out.println("耗时"+ (System.currentTimeMillis()-start));
    }

}